<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<title>TestHTML</title>
<script type="text/javascript" src="./SComet.js"></script>
</head>
<body onunload="conns.close()">
	<textarea id="show" rows="10" cols="20"></textarea>
	<br />
	<input id="text" type="text" />
	<input value="click me" type="button" onclick="button_click()" />
	<script type="text/javascript">
		var conns = SComet.getSComet();

		var show = document.getElementById("show");

		conns.setCallBack(function(message) {
			show.innerHTML += message;
		});

		conns.link(conns);

		var text = document.getElementById("text");

		var button_click = function() {
			conns.send(text.value);
		};
	</script>

</body>
</html>
